
const options = [
	{
		label: '订单号',
		value: 'id',
		type: 'text',
		selected: true,
		placeholder: '请输入订单号'
	},
	{
		label: '类型',
		value: 'type',
		type: 'select',
		operator: '=',
		selected: true,
		placeholder: '请选择类型',
		extend: {
			data: [
				{
					label: '选项1',
					value: '1'
				},
				{
					label: '选项2',
					value: '2'
				}
			]
		}
	},
	{
		label: '类型(多选)',
		value: 'type2',
		type: 'select',
		operator: '=',
		placeholder: '请选择类型',
		extend: {
			multiple: true,
			data: [
				{
					label: '选项1',
					value: '1'
				},
				{
					label: '选项2',
					value: '2'
				}
			]
		}
	},
	{
		label: '通知(异步)',
		value: 'noticeType',
		type: 'select',
		operator: '=',
		placeholder: '请选择通知类型',
		extend: {
			request: async () => {
				var list = await this.$API.system.dic.get.get()
				return list.data.map((item) => {
					return {
						label: item.label,
						value: item.value
					}
				})
			}
		}
	},
	{
		label: '通知(远程搜索)',
		value: 'noticeType2',
		type: 'select',
		operator: '=',
		placeholder: '请输入关键词后检索',
		extend: {
			remote: true,
			request: async (query) => {
				var data = {
					keyword: query
				}
				var list = await this.$API.system.dic.get.get(data)
				return list.data.map((item) => {
					return {
						label: item.label,
						value: item.value
					}
				})
			}
		}
	},
	{
		label: '关键词(标签)',
		value: 'tags',
		type: 'tags',
		operator: 'include',
		operators: [
			{
				label: '包含',
				value: 'include'
			},
			{
				label: '不包含',
				value: 'notinclude'
			}
		]
	},
	{
		label: '开关',
		value: 'switch',
		type: 'switch',
		operator: '='
	},
	{
		label: '日期单选',
		value: 'date',
		type: 'date',
		operator: '=',
		operators: [
			{
				label: '等于',
				value: '='
			},
			{
				label: '不等于',
				value: '!='
			}
		]
	},
	{
		label: '日期范围',
		value: 'date2',
		type: 'daterange'
	}
]

export default options;
